/**
 * Klasse Teacher klasse tbv. kantine simulatie, welke leraren definiëerd
 * @author (Stephan Veenstra, Michel Jansma) 
 * @version (1.8)
 */

public class Teacher extends Person {

    //Instantie variabelen definiëren van het type String
    private String department;

    /**
     * @method Teacher
     * @params null
     * @info   Constructor van Teacher class, welke geen parameters meekrijgt
     * @return null
     */
    public Teacher() {
        //Call to super class
        super(109867, "Steve", "Mclaren", 'M', new int[]{ 10, 2, 1972 });
        //Initialiseer instantie variabele department
        this.setDepartment("Informatica");
    }

    /**
     * @method Teacher
     * @params <int> BSN, <String> firstname, <String> lastname, <char> gender, <int[]> dateOfBirth, <String> department
     * @info   Overloaded constructor van Student class
     * @return null
     */
    public Teacher(int BSN, String firstname, String lastname, char gender, int[]dateOfBirth, String department) {
        //Call to super class
        super(BSN, firstname, lastname, gender, dateOfBirth);
        //Initialiseer instantie variabele department
        this.setDepartment(department);
    }
    
    /**
     * SETTER METHODES
     */
    
    /**
     * @method setDepartment
     * @params <String> department
     * @info   Initialiseer instantie variabele department
     * @return null
     */
    public void setDepartment(String department) {
        this.department = department;
    }
    
    /**
     * GETTER METHODES
     */
    
    /**
     * @method getDepartment
     * @params null
     * @info   Retourneer instantie variabele department
     * @return <String> department
     */
    public String getDepartment() {
        return this.department;
    }
    
    /**
     * @method getAbbreviation
     * @params null
     * @info   Retourneer 4L. afkorting leraar
     * @return <String> abbreviation
     */
    public String getAbbreviation() {
        return this.getLastname().substring(0,2) + this.getFirstname().substring(0,2);
    }
    
    /**
     * @method getData
     * @params null
     * @info   Toon specifieke leraar data
     * @return null
     */
    @Override
    public void getData() {
        //Toon specifieke leraar data
        System.out.println(
            "L.Afkorting : " + this.getAbbreviation() + "\n" +
            "Afdeling    : " + this.getDepartment()
        );
    } 
    
}
